﻿<?php
    require_once (dirname(__FILE__).'/includes/tpl_config.php');
	require_once (dirname(__FILE__).'/includes/dbconn.php');
	
	$tpl->assign("title","公告板");
	require_once 'navi.php';
	
	$tpl->assign("header","IBM俱乐部公告板");
	$tpl->display('page_top.tpl');
	
	$sql="select anid,uname,title,to_char(time, 'YYYY-MM-DD  HH24:MI:SS') from announce order by time desc";
	$result = $db->sql_query($sql);
    $rowset = $db->sql_fetchrowset($result);
	$db->sql_freeresult($result);
	$tpl->assign("annrows",$rowset);   //将结果集回显
	$tpl->display('announce.tpl');
	$tpl->display('footer.tpl');
?>
